﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Interop;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Shapes;

namespace PaiBanDaPing
{
    /// <summary>
    /// DaPingWin.xaml 的交互逻辑
    /// </summary>
    public partial class DaPingDisplayWin : Window
    {
        public DaPingDisplayWin()
        {
            InitializeComponent();
        }

        /// <summary>
        /// 设置窗体显示样式 1：正常模式 2：无任何样式
        /// </summary>
        public int DisplayStyle
        {
            set
            {
                if (value == 1)
                {
                    this.WindowStyle = WindowStyle.ThreeDBorderWindow;
                }
                else if (value == 2)
                {
                    this.WindowStyle = WindowStyle.None;
                }
                
            }
        }
        public void DisPlay(CustomScreenModel obj)
        {
            try
            {
                _web.Address=obj.Url;
            }
            catch (Exception ex)
            {
                MessageBox.Show(ex.ToString());
            }
        }
    }
}
